import request from '@/utils/request'

// 查询围栏信息列表
export function listFenceinfo(query) {
  return request({
    url: '/fence/fenceinfo/list',
    method: 'get',
    params: query
  })
}

// 查询围栏信息详细
export function getFenceinfo(id) {
  return request({
    url: '/fence/fenceinfo/' + id,
    method: 'get'
  })
}

// 新增围栏信息
export function addFenceinfo(data) {
  return request({
    url: '/fence/fenceinfo',
    method: 'post',
    data: data
  })
}

// 修改围栏信息
export function updateFenceinfo(data) {
  return request({
    url: '/fence/fenceinfo',
    method: 'put',
    data: data
  })
}

// 删除围栏信息
export function delFenceinfo(id) {
  return request({
    url: '/fence/fenceinfo/' + id,
    method: 'delete'
  })
}

export function addcoordinate(data) {
  return request({
    url: '/fence/fenceinfo/addcoordinate',
    method: 'post',
    data
  })
}
// export function listredis(query) {
//   return request({
//     url: '/fence/fenceinfo/listredis',
//     method: 'get',
//     params: query
//   })
// }